// $ANTLR 3.1.2 /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g 2012-07-31 10:35:47

package etxt2db.ucompare.query;

import etxt2db.api.ClassificationModel;
import etxt2db.api.ClassificationModelCreator;
import etxt2db.features.*;
import etxt2db.serialization.*;


import java.io.IOException;
import java.util.LinkedList;


import org.antlr.runtime.*;
import java.util.List;
import java.util.ArrayList;

public class Etxt2DBGrammarParser extends Parser {
    public static final String[] tokenNames = new String[] {
        "<invalid>", "<EOR>", "<DOWN>", "<UP>", "CREATE", "CLASSIFICATION", "MODEL", "AS", "GENERIC_NAME", "WITH", "STRING", "CONTEXT", "DOCUMENT", "PARAGRAPH", "SENTENCE", "LINE", "TOKENIZED", "UCOMPARE", "USING", "REGEX", "TO", "FIND", "DICTIONARY", "HMM", "TRAINED", "UNION", "COMMA", "CASE", "SENSITIVE", "INSENSITIVE", "MEMM", "CRF", "SVM", "CAPTURING", "FEATURES", "IN", "WINDOW", "RADIUS", "NUMBER", "SUBSTRING", "FROM", "MATCH", "VALUE", "SIZE", "CHARACTER", "PATTERN", "TYPE", "CLASSIFY", "EVALUATE", "OF", "SET", "BEGIN", "TAG", "END", "STYLE", "ONE", "PER", "FILE", "C", "O", "N", "T", "E", "X", "P", "A", "R", "G", "H", "S", "K", "I", "Z", "D", "U", "M", "L", "F", "Y", "CLASSES", "V", "CORPUS", "B", "W", "PLUS", "MINUS", "LETTER", "NAMECHAR", "DIGIT", "J", "Q", "WS", "'*'"
    };
    public static final int LETTER=86;
    public static final int CASE=27;
    public static final int REGEX=19;
    public static final int ONE=55;
    public static final int CAPTURING=33;
    public static final int EOF=-1;
    public static final int CHARACTER=44;
    public static final int TYPE=46;
    public static final int PATTERN=45;
    public static final int CREATE=4;
    public static final int T__92=92;
    public static final int DICTIONARY=22;
    public static final int USING=18;
    public static final int SENTENCE=14;
    public static final int BEGIN=51;
    public static final int CLASSIFY=47;
    public static final int EVALUATE=48;
    public static final int D=73;
    public static final int E=62;
    public static final int F=77;
    public static final int G=67;
    public static final int A=65;
    public static final int B=82;
    public static final int C=58;
    public static final int L=76;
    public static final int M=75;
    public static final int N=60;
    public static final int O=59;
    public static final int H=68;
    public static final int I=71;
    public static final int J=89;
    public static final int NUMBER=38;
    public static final int K=70;
    public static final int U=74;
    public static final int T=61;
    public static final int W=83;
    public static final int MATCH=41;
    public static final int SENSITIVE=28;
    public static final int V=80;
    public static final int Q=90;
    public static final int P=64;
    public static final int S=69;
    public static final int VALUE=42;
    public static final int R=66;
    public static final int OF=49;
    public static final int FILE=57;
    public static final int GENERIC_NAME=8;
    public static final int Y=78;
    public static final int X=63;
    public static final int Z=72;
    public static final int NAMECHAR=87;
    public static final int WS=91;
    public static final int INSENSITIVE=29;
    public static final int STYLE=54;
    public static final int FROM=40;
    public static final int END=53;
    public static final int SIZE=43;
    public static final int RADIUS=37;
    public static final int FIND=21;
    public static final int MEMM=30;
    public static final int CLASSES=79;
    public static final int CONTEXT=11;
    public static final int AS=7;
    public static final int TRAINED=24;
    public static final int IN=35;
    public static final int PARAGRAPH=13;
    public static final int DOCUMENT=12;
    public static final int COMMA=26;
    public static final int HMM=23;
    public static final int MODEL=6;
    public static final int PLUS=84;
    public static final int CORPUS=81;
    public static final int DIGIT=88;
    public static final int WITH=9;
    public static final int FEATURES=34;
    public static final int TO=20;
    public static final int PER=56;
    public static final int SET=50;
    public static final int MINUS=85;
    public static final int CLASSIFICATION=5;
    public static final int LINE=15;
    public static final int UNION=25;
    public static final int SUBSTRING=39;
    public static final int TAG=52;
    public static final int TOKENIZED=16;
    public static final int WINDOW=36;
    public static final int UCOMPARE=17;
    public static final int CRF=31;
    public static final int STRING=10;
    public static final int SVM=32;

    // delegates
    // delegators


        public Etxt2DBGrammarParser(TokenStream input) {
            this(input, new RecognizerSharedState());
        }
        public Etxt2DBGrammarParser(TokenStream input, RecognizerSharedState state) {
            super(input, state);
             
        }
        

    public String[] getTokenNames() { return Etxt2DBGrammarParser.tokenNames; }
    public String getGrammarFileName() { return "/home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g"; }


        public static int TRAINING = 0;
        public static int CLASSIFYING = 1;
        public static int EVALUATING = 2;
        public static int SETBEGINTAG = 3;
        public static int SETENDTAG = 4;
        public static int SETDOCPERFILE = 5;
        public static int NOTHING = 6;
        public static final int EXPREG = 0;
        public static final int DICTIO = 1;
        public static final int MACLEA = 2;
        public static final int CUNION = 3;
        public static final int NOTECH = 4;
        
        /* RUI */
        public static final int DOCUM = 0;
        public static final int PARAG = 1;
        public static final int SENT = 2;
        public static final int PERLINE = 3;
        
        private List<String> errors = new ArrayList<String>();
        public List<QueryInformationObject> queries = new LinkedList<QueryInformationObject>();
        private QueryInformationObject current = new QueryInformationObject();
        
        public void displayRecognitionError(String[] tokenNames,
                                            RecognitionException e) {
            String hdr = getErrorHeader(e);
            String msg = getErrorMessage(e, tokenNames);
            errors.add(hdr + " " + msg);

        }
        
        public String getErrorHeader(RecognitionException e) {
            int numLine;
            if(e.token.equals(Token.EOF_TOKEN)){
                 return "Error in the end of the file";
            }else{
                 numLine = e.token.getLine();
            }
            return "Error in line "+numLine+":"+e.token.getCharPositionInLine() + " : ";
        }

        
        public String getTokenErrorDisplay(Token t) {
          return super.getTokenErrorDisplay(t);
        }
        
        public List<String> getErrors() {
            return errors;
        }





    // $ANTLR start "root"
    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:77:1: root : ( train | classify | evaluate | setBeginTag | setEndTag | setDocPerFile )+ ;
    public final void root() throws RecognitionException {
        try {
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:77:7: ( ( train | classify | evaluate | setBeginTag | setEndTag | setDocPerFile )+ )
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:77:9: ( train | classify | evaluate | setBeginTag | setEndTag | setDocPerFile )+
            {
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:77:9: ( train | classify | evaluate | setBeginTag | setEndTag | setDocPerFile )+
            int cnt1=0;
            loop1:
            do {
                int alt1=7;
                switch ( input.LA(1) ) {
                case CREATE:
                    {
                    alt1=1;
                    }
                    break;
                case CLASSIFY:
                    {
                    alt1=2;
                    }
                    break;
                case EVALUATE:
                    {
                    alt1=3;
                    }
                    break;
                case SET:
                    {
                    switch ( input.LA(2) ) {
                    case BEGIN:
                        {
                        alt1=4;
                        }
                        break;
                    case END:
                        {
                        alt1=5;
                        }
                        break;
                    case DOCUMENT:
                        {
                        alt1=6;
                        }
                        break;

                    }

                    }
                    break;

                }

                switch (alt1) {
            	case 1 :
            	    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:77:10: train
            	    {
            	    pushFollow(FOLLOW_train_in_root35);
            	    train();

            	    state._fsp--;

            	    current.setAction(TRAINING);queries.add(current); current = new QueryInformationObject();

            	    }
            	    break;
            	case 2 :
            	    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:78:5: classify
            	    {
            	    pushFollow(FOLLOW_classify_in_root44);
            	    classify();

            	    state._fsp--;

            	    current.setAction(CLASSIFYING);queries.add(current); current = new QueryInformationObject();

            	    }
            	    break;
            	case 3 :
            	    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:79:5: evaluate
            	    {
            	    pushFollow(FOLLOW_evaluate_in_root53);
            	    evaluate();

            	    state._fsp--;

            	    current.setAction(EVALUATING);queries.add(current); current = new QueryInformationObject();

            	    }
            	    break;
            	case 4 :
            	    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:80:5: setBeginTag
            	    {
            	    pushFollow(FOLLOW_setBeginTag_in_root61);
            	    setBeginTag();

            	    state._fsp--;

            	    current.setAction(SETBEGINTAG);queries.add(current); current = new QueryInformationObject();

            	    }
            	    break;
            	case 5 :
            	    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:81:5: setEndTag
            	    {
            	    pushFollow(FOLLOW_setEndTag_in_root70);
            	    setEndTag();

            	    state._fsp--;

            	    current.setAction(SETENDTAG);queries.add(current); current = new QueryInformationObject();

            	    }
            	    break;
            	case 6 :
            	    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:82:5: setDocPerFile
            	    {
            	    pushFollow(FOLLOW_setDocPerFile_in_root78);
            	    setDocPerFile();

            	    state._fsp--;

            	    current.setAction(SETDOCPERFILE);queries.add(current); current = new QueryInformationObject();

            	    }
            	    break;

            	default :
            	    if ( cnt1 >= 1 ) break loop1;
                        EarlyExitException eee =
                            new EarlyExitException(1, input);
                        throw eee;
                }
                cnt1++;
            } while (true);


            }

        }
        catch (RecognitionException re) {
            reportError(re);
            recover(input,re);
        }
        finally {
        }
        return ;
    }
    // $ANTLR end "root"


    // $ANTLR start "train"
    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:85:1: train : trainHeader ( workflow )? ( context )? ( tokenization )? technique ;
    public final void train() throws RecognitionException {
        try {
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:85:9: ( trainHeader ( workflow )? ( context )? ( tokenization )? technique )
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:85:11: trainHeader ( workflow )? ( context )? ( tokenization )? technique
            {
            pushFollow(FOLLOW_trainHeader_in_train94);
            trainHeader();

            state._fsp--;

            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:85:23: ( workflow )?
            int alt2=2;
            int LA2_0 = input.LA(1);

            if ( (LA2_0==WITH) ) {
                alt2=1;
            }
            switch (alt2) {
                case 1 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:85:23: workflow
                    {
                    pushFollow(FOLLOW_workflow_in_train96);
                    workflow();

                    state._fsp--;


                    }
                    break;

            }

            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:85:33: ( context )?
            int alt3=2;
            int LA3_0 = input.LA(1);

            if ( (LA3_0==CONTEXT) ) {
                alt3=1;
            }
            switch (alt3) {
                case 1 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:85:33: context
                    {
                    pushFollow(FOLLOW_context_in_train99);
                    context();

                    state._fsp--;


                    }
                    break;

            }

            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:85:42: ( tokenization )?
            int alt4=2;
            int LA4_0 = input.LA(1);

            if ( (LA4_0==TOKENIZED) ) {
                alt4=1;
            }
            switch (alt4) {
                case 1 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:85:42: tokenization
                    {
                    pushFollow(FOLLOW_tokenization_in_train102);
                    tokenization();

                    state._fsp--;


                    }
                    break;

            }

            pushFollow(FOLLOW_technique_in_train105);
            technique();

            state._fsp--;


            }

        }
        catch (RecognitionException re) {
            reportError(re);
            recover(input,re);
        }
        finally {
        }
        return ;
    }
    // $ANTLR end "train"


    // $ANTLR start "trainHeader"
    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:88:1: trainHeader : CREATE CLASSIFICATION MODEL AS GENERIC_NAME ;
    public final void trainHeader() throws RecognitionException {
        Token GENERIC_NAME1=null;

        try {
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:89:3: ( CREATE CLASSIFICATION MODEL AS GENERIC_NAME )
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:89:5: CREATE CLASSIFICATION MODEL AS GENERIC_NAME
            {
            match(input,CREATE,FOLLOW_CREATE_in_trainHeader119); 
            match(input,CLASSIFICATION,FOLLOW_CLASSIFICATION_in_trainHeader121); 
            match(input,MODEL,FOLLOW_MODEL_in_trainHeader123); 
            match(input,AS,FOLLOW_AS_in_trainHeader125); 
            GENERIC_NAME1=(Token)match(input,GENERIC_NAME,FOLLOW_GENERIC_NAME_in_trainHeader127); 
            current.setAnnotatorName((GENERIC_NAME1!=null?GENERIC_NAME1.getText():null));

            }

        }
        catch (RecognitionException re) {
            reportError(re);
            recover(input,re);
        }
        finally {
        }
        return ;
    }
    // $ANTLR end "trainHeader"


    // $ANTLR start "workflow"
    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:91:1: workflow : WITH STRING ;
    public final void workflow() throws RecognitionException {
        Token STRING2=null;

        try {
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:92:3: ( WITH STRING )
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:92:5: WITH STRING
            {
            match(input,WITH,FOLLOW_WITH_in_workflow139); 
            STRING2=(Token)match(input,STRING,FOLLOW_STRING_in_workflow141); 
            current.setWorkflowFile((STRING2!=null?STRING2.getText():null).substring(1,(STRING2!=null?STRING2.getText():null).length()-1));

            }

        }
        catch (RecognitionException re) {
            reportError(re);
            recover(input,re);
        }
        finally {
        }
        return ;
    }
    // $ANTLR end "workflow"


    // $ANTLR start "context"
    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:95:1: context : CONTEXT context_name ;
    public final void context() throws RecognitionException {
        try {
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:96:3: ( CONTEXT context_name )
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:96:5: CONTEXT context_name
            {
            match(input,CONTEXT,FOLLOW_CONTEXT_in_context154); 
            pushFollow(FOLLOW_context_name_in_context156);
            context_name();

            state._fsp--;


            }

        }
        catch (RecognitionException re) {
            reportError(re);
            recover(input,re);
        }
        finally {
        }
        return ;
    }
    // $ANTLR end "context"


    // $ANTLR start "context_name"
    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:97:1: context_name : ( DOCUMENT | PARAGRAPH | SENTENCE | LINE );
    public final void context_name() throws RecognitionException {
        try {
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:98:3: ( DOCUMENT | PARAGRAPH | SENTENCE | LINE )
            int alt5=4;
            switch ( input.LA(1) ) {
            case DOCUMENT:
                {
                alt5=1;
                }
                break;
            case PARAGRAPH:
                {
                alt5=2;
                }
                break;
            case SENTENCE:
                {
                alt5=3;
                }
                break;
            case LINE:
                {
                alt5=4;
                }
                break;
            default:
                NoViableAltException nvae =
                    new NoViableAltException("", 5, 0, input);

                throw nvae;
            }

            switch (alt5) {
                case 1 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:98:5: DOCUMENT
                    {
                    match(input,DOCUMENT,FOLLOW_DOCUMENT_in_context_name165); 
                    current.setContext(DOCUM);

                    }
                    break;
                case 2 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:99:5: PARAGRAPH
                    {
                    match(input,PARAGRAPH,FOLLOW_PARAGRAPH_in_context_name173); 
                    current.setContext(PARAG);

                    }
                    break;
                case 3 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:100:5: SENTENCE
                    {
                    match(input,SENTENCE,FOLLOW_SENTENCE_in_context_name181); 
                    current.setContext(SENT);

                    }
                    break;
                case 4 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:101:5: LINE
                    {
                    match(input,LINE,FOLLOW_LINE_in_context_name189); 
                    current.setContext(PERLINE);

                    }
                    break;

            }
        }
        catch (RecognitionException re) {
            reportError(re);
            recover(input,re);
        }
        finally {
        }
        return ;
    }
    // $ANTLR end "context_name"


    // $ANTLR start "tokenization"
    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:103:1: tokenization : TOKENIZED WITH UCOMPARE GENERIC_NAME ;
    public final void tokenization() throws RecognitionException {
        Token GENERIC_NAME3=null;

        try {
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:104:3: ( TOKENIZED WITH UCOMPARE GENERIC_NAME )
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:104:5: TOKENIZED WITH UCOMPARE GENERIC_NAME
            {
            match(input,TOKENIZED,FOLLOW_TOKENIZED_in_tokenization201); 
            match(input,WITH,FOLLOW_WITH_in_tokenization203); 
            match(input,UCOMPARE,FOLLOW_UCOMPARE_in_tokenization205); 
            GENERIC_NAME3=(Token)match(input,GENERIC_NAME,FOLLOW_GENERIC_NAME_in_tokenization207); 
            current.setTokenizerName((GENERIC_NAME3!=null?GENERIC_NAME3.getText():null));

            }

        }
        catch (RecognitionException re) {
            reportError(re);
            recover(input,re);
        }
        finally {
        }
        return ;
    }
    // $ANTLR end "tokenization"


    // $ANTLR start "technique"
    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:106:1: technique : ( ( USING REGEX STRING TO FIND GENERIC_NAME ) | ( USING ( caseSelection )? DICTIONARY STRING ) | ( USING HMM TRAINED WITH STRING TO FIND listClasses ) | ( USING mlTech TRAINED WITH STRING TO FIND listClasses ( features )? ) | ( USING CLASSIFICATION MODEL UNION listClassifiers ) );
    public final void technique() throws RecognitionException {
        Token STRING4=null;
        Token GENERIC_NAME5=null;
        Token STRING6=null;
        Token STRING7=null;
        Token STRING8=null;

        try {
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:107:3: ( ( USING REGEX STRING TO FIND GENERIC_NAME ) | ( USING ( caseSelection )? DICTIONARY STRING ) | ( USING HMM TRAINED WITH STRING TO FIND listClasses ) | ( USING mlTech TRAINED WITH STRING TO FIND listClasses ( features )? ) | ( USING CLASSIFICATION MODEL UNION listClassifiers ) )
            int alt8=5;
            int LA8_0 = input.LA(1);

            if ( (LA8_0==USING) ) {
                switch ( input.LA(2) ) {
                case REGEX:
                    {
                    alt8=1;
                    }
                    break;
                case HMM:
                    {
                    alt8=3;
                    }
                    break;
                case CLASSIFICATION:
                    {
                    alt8=5;
                    }
                    break;
                case DICTIONARY:
                case CASE:
                    {
                    alt8=2;
                    }
                    break;
                case MEMM:
                case CRF:
                case SVM:
                    {
                    alt8=4;
                    }
                    break;
                default:
                    NoViableAltException nvae =
                        new NoViableAltException("", 8, 1, input);

                    throw nvae;
                }

            }
            else {
                NoViableAltException nvae =
                    new NoViableAltException("", 8, 0, input);

                throw nvae;
            }
            switch (alt8) {
                case 1 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:107:5: ( USING REGEX STRING TO FIND GENERIC_NAME )
                    {
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:107:5: ( USING REGEX STRING TO FIND GENERIC_NAME )
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:107:6: USING REGEX STRING TO FIND GENERIC_NAME
                    {
                    match(input,USING,FOLLOW_USING_in_technique220); 
                    match(input,REGEX,FOLLOW_REGEX_in_technique222); 
                    STRING4=(Token)match(input,STRING,FOLLOW_STRING_in_technique224); 
                    match(input,TO,FOLLOW_TO_in_technique226); 
                    match(input,FIND,FOLLOW_FIND_in_technique228); 
                    GENERIC_NAME5=(Token)match(input,GENERIC_NAME,FOLLOW_GENERIC_NAME_in_technique230); 

                    }

                     current.setTechniqueUsed(EXPREG); current.setRegularExpression((STRING4!=null?STRING4.getText():null).substring(1,(STRING4!=null?STRING4.getText():null).length()-1)); current.setRegularExpressionType((GENERIC_NAME5!=null?GENERIC_NAME5.getText():null)); 

                    }
                    break;
                case 2 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:108:5: ( USING ( caseSelection )? DICTIONARY STRING )
                    {
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:108:5: ( USING ( caseSelection )? DICTIONARY STRING )
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:108:6: USING ( caseSelection )? DICTIONARY STRING
                    {
                    match(input,USING,FOLLOW_USING_in_technique240); 
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:108:12: ( caseSelection )?
                    int alt6=2;
                    int LA6_0 = input.LA(1);

                    if ( (LA6_0==CASE) ) {
                        alt6=1;
                    }
                    switch (alt6) {
                        case 1 :
                            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:108:12: caseSelection
                            {
                            pushFollow(FOLLOW_caseSelection_in_technique242);
                            caseSelection();

                            state._fsp--;


                            }
                            break;

                    }

                    match(input,DICTIONARY,FOLLOW_DICTIONARY_in_technique245); 
                    STRING6=(Token)match(input,STRING,FOLLOW_STRING_in_technique247); 

                    }

                     current.setTechniqueUsed(DICTIO); current.setDictionaryPath((STRING6!=null?STRING6.getText():null).substring(1,(STRING6!=null?STRING6.getText():null).length()-1));

                    }
                    break;
                case 3 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:109:5: ( USING HMM TRAINED WITH STRING TO FIND listClasses )
                    {
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:109:5: ( USING HMM TRAINED WITH STRING TO FIND listClasses )
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:109:6: USING HMM TRAINED WITH STRING TO FIND listClasses
                    {
                    match(input,USING,FOLLOW_USING_in_technique258); 
                    match(input,HMM,FOLLOW_HMM_in_technique260); 
                    match(input,TRAINED,FOLLOW_TRAINED_in_technique262); 
                    match(input,WITH,FOLLOW_WITH_in_technique264); 
                    STRING7=(Token)match(input,STRING,FOLLOW_STRING_in_technique266); 
                    match(input,TO,FOLLOW_TO_in_technique268); 
                    match(input,FIND,FOLLOW_FIND_in_technique270); 
                    pushFollow(FOLLOW_listClasses_in_technique272);
                    listClasses();

                    state._fsp--;


                    }

                     current.setTechniqueUsed(MACLEA);
                              current.setMachineLearningTrainingPath((STRING7!=null?STRING7.getText():null).substring(1,(STRING7!=null?STRING7.getText():null).length()-1));
                              current.setMachineLearningTechnique(ClassificationModelCreator.MLTechnique.HMM);

                    }
                    break;
                case 4 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:115:5: ( USING mlTech TRAINED WITH STRING TO FIND listClasses ( features )? )
                    {
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:115:5: ( USING mlTech TRAINED WITH STRING TO FIND listClasses ( features )? )
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:115:6: USING mlTech TRAINED WITH STRING TO FIND listClasses ( features )?
                    {
                    match(input,USING,FOLLOW_USING_in_technique296); 
                    pushFollow(FOLLOW_mlTech_in_technique298);
                    mlTech();

                    state._fsp--;

                    match(input,TRAINED,FOLLOW_TRAINED_in_technique300); 
                    match(input,WITH,FOLLOW_WITH_in_technique302); 
                    STRING8=(Token)match(input,STRING,FOLLOW_STRING_in_technique304); 
                    match(input,TO,FOLLOW_TO_in_technique306); 
                    match(input,FIND,FOLLOW_FIND_in_technique308); 
                    pushFollow(FOLLOW_listClasses_in_technique310);
                    listClasses();

                    state._fsp--;

                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:115:59: ( features )?
                    int alt7=2;
                    int LA7_0 = input.LA(1);

                    if ( (LA7_0==CAPTURING) ) {
                        alt7=1;
                    }
                    switch (alt7) {
                        case 1 :
                            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:115:59: features
                            {
                            pushFollow(FOLLOW_features_in_technique312);
                            features();

                            state._fsp--;


                            }
                            break;

                    }


                    }

                     current.setTechniqueUsed(MACLEA);
                              current.setMachineLearningTrainingPath((STRING8!=null?STRING8.getText():null).substring(1,(STRING8!=null?STRING8.getText():null).length()-1));

                    }
                    break;
                case 5 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:118:5: ( USING CLASSIFICATION MODEL UNION listClassifiers )
                    {
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:118:5: ( USING CLASSIFICATION MODEL UNION listClassifiers )
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:118:6: USING CLASSIFICATION MODEL UNION listClassifiers
                    {
                    match(input,USING,FOLLOW_USING_in_technique331); 
                    match(input,CLASSIFICATION,FOLLOW_CLASSIFICATION_in_technique333); 
                    match(input,MODEL,FOLLOW_MODEL_in_technique335); 
                    match(input,UNION,FOLLOW_UNION_in_technique337); 
                    pushFollow(FOLLOW_listClassifiers_in_technique339);
                    listClassifiers();

                    state._fsp--;


                    }

                     current.setTechniqueUsed(CUNION);

                    }
                    break;

            }
        }
        catch (RecognitionException re) {
            reportError(re);
            recover(input,re);
        }
        finally {
        }
        return ;
    }
    // $ANTLR end "technique"


    // $ANTLR start "listClassifiers"
    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:120:1: listClassifiers : ( GENERIC_NAME | GENERIC_NAME COMMA listClassifiers );
    public final void listClassifiers() throws RecognitionException {
        Token GENERIC_NAME9=null;
        Token GENERIC_NAME10=null;

        try {
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:121:3: ( GENERIC_NAME | GENERIC_NAME COMMA listClassifiers )
            int alt9=2;
            int LA9_0 = input.LA(1);

            if ( (LA9_0==GENERIC_NAME) ) {
                int LA9_1 = input.LA(2);

                if ( (LA9_1==COMMA) ) {
                    alt9=2;
                }
                else if ( (LA9_1==EOF||LA9_1==CREATE||(LA9_1>=CLASSIFY && LA9_1<=EVALUATE)||LA9_1==SET) ) {
                    alt9=1;
                }
                else {
                    NoViableAltException nvae =
                        new NoViableAltException("", 9, 1, input);

                    throw nvae;
                }
            }
            else {
                NoViableAltException nvae =
                    new NoViableAltException("", 9, 0, input);

                throw nvae;
            }
            switch (alt9) {
                case 1 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:121:5: GENERIC_NAME
                    {
                    GENERIC_NAME9=(Token)match(input,GENERIC_NAME,FOLLOW_GENERIC_NAME_in_listClassifiers352); 
                    current.addAnnotator((GENERIC_NAME9!=null?GENERIC_NAME9.getText():null));

                    }
                    break;
                case 2 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:122:5: GENERIC_NAME COMMA listClassifiers
                    {
                    GENERIC_NAME10=(Token)match(input,GENERIC_NAME,FOLLOW_GENERIC_NAME_in_listClassifiers367); 
                    match(input,COMMA,FOLLOW_COMMA_in_listClassifiers369); 
                    pushFollow(FOLLOW_listClassifiers_in_listClassifiers371);
                    listClassifiers();

                    state._fsp--;

                    current.addAnnotator((GENERIC_NAME10!=null?GENERIC_NAME10.getText():null));

                    }
                    break;

            }
        }
        catch (RecognitionException re) {
            reportError(re);
            recover(input,re);
        }
        finally {
        }
        return ;
    }
    // $ANTLR end "listClassifiers"


    // $ANTLR start "caseSelection"
    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:124:1: caseSelection : CASE ( ( SENSITIVE ) | ( INSENSITIVE ) ) ;
    public final void caseSelection() throws RecognitionException {
        try {
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:125:3: ( CASE ( ( SENSITIVE ) | ( INSENSITIVE ) ) )
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:125:5: CASE ( ( SENSITIVE ) | ( INSENSITIVE ) )
            {
            match(input,CASE,FOLLOW_CASE_in_caseSelection385); 
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:125:10: ( ( SENSITIVE ) | ( INSENSITIVE ) )
            int alt10=2;
            int LA10_0 = input.LA(1);

            if ( (LA10_0==SENSITIVE) ) {
                alt10=1;
            }
            else if ( (LA10_0==INSENSITIVE) ) {
                alt10=2;
            }
            else {
                NoViableAltException nvae =
                    new NoViableAltException("", 10, 0, input);

                throw nvae;
            }
            switch (alt10) {
                case 1 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:125:11: ( SENSITIVE )
                    {
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:125:11: ( SENSITIVE )
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:125:12: SENSITIVE
                    {
                    match(input,SENSITIVE,FOLLOW_SENSITIVE_in_caseSelection389); 

                    }

                    current.setDictionaryCase(true);

                    }
                    break;
                case 2 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:125:59: ( INSENSITIVE )
                    {
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:125:59: ( INSENSITIVE )
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:125:60: INSENSITIVE
                    {
                    match(input,INSENSITIVE,FOLLOW_INSENSITIVE_in_caseSelection396); 

                    }

                    current.setDictionaryCase(false);

                    }
                    break;

            }


            }

        }
        catch (RecognitionException re) {
            reportError(re);
            recover(input,re);
        }
        finally {
        }
        return ;
    }
    // $ANTLR end "caseSelection"


    // $ANTLR start "listClasses"
    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:127:1: listClasses : ( listNames | ( '*' ) );
    public final void listClasses() throws RecognitionException {
        try {
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:128:3: ( listNames | ( '*' ) )
            int alt11=2;
            int LA11_0 = input.LA(1);

            if ( (LA11_0==GENERIC_NAME) ) {
                alt11=1;
            }
            else if ( (LA11_0==92) ) {
                alt11=2;
            }
            else {
                NoViableAltException nvae =
                    new NoViableAltException("", 11, 0, input);

                throw nvae;
            }
            switch (alt11) {
                case 1 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:128:5: listNames
                    {
                    pushFollow(FOLLOW_listNames_in_listClasses410);
                    listNames();

                    state._fsp--;


                    }
                    break;
                case 2 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:129:5: ( '*' )
                    {
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:129:5: ( '*' )
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:129:6: '*'
                    {
                    match(input,92,FOLLOW_92_in_listClasses417); 

                    }

                    current.setTypesList(null);

                    }
                    break;

            }
        }
        catch (RecognitionException re) {
            reportError(re);
            recover(input,re);
        }
        finally {
        }
        return ;
    }
    // $ANTLR end "listClasses"


    // $ANTLR start "listNames"
    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:131:1: listNames : ( GENERIC_NAME | GENERIC_NAME COMMA listNames );
    public final void listNames() throws RecognitionException {
        Token GENERIC_NAME11=null;
        Token GENERIC_NAME12=null;

        try {
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:132:3: ( GENERIC_NAME | GENERIC_NAME COMMA listNames )
            int alt12=2;
            int LA12_0 = input.LA(1);

            if ( (LA12_0==GENERIC_NAME) ) {
                int LA12_1 = input.LA(2);

                if ( (LA12_1==COMMA) ) {
                    alt12=2;
                }
                else if ( (LA12_1==EOF||LA12_1==CREATE||LA12_1==CAPTURING||LA12_1==FROM||(LA12_1>=CLASSIFY && LA12_1<=EVALUATE)||LA12_1==SET) ) {
                    alt12=1;
                }
                else {
                    NoViableAltException nvae =
                        new NoViableAltException("", 12, 1, input);

                    throw nvae;
                }
            }
            else {
                NoViableAltException nvae =
                    new NoViableAltException("", 12, 0, input);

                throw nvae;
            }
            switch (alt12) {
                case 1 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:132:5: GENERIC_NAME
                    {
                    GENERIC_NAME11=(Token)match(input,GENERIC_NAME,FOLLOW_GENERIC_NAME_in_listNames433); 
                    current.addType((GENERIC_NAME11!=null?GENERIC_NAME11.getText():null));

                    }
                    break;
                case 2 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:133:5: GENERIC_NAME COMMA listNames
                    {
                    GENERIC_NAME12=(Token)match(input,GENERIC_NAME,FOLLOW_GENERIC_NAME_in_listNames446); 
                    match(input,COMMA,FOLLOW_COMMA_in_listNames448); 
                    pushFollow(FOLLOW_listNames_in_listNames450);
                    listNames();

                    state._fsp--;

                    current.addType((GENERIC_NAME12!=null?GENERIC_NAME12.getText():null));

                    }
                    break;

            }
        }
        catch (RecognitionException re) {
            reportError(re);
            recover(input,re);
        }
        finally {
        }
        return ;
    }
    // $ANTLR end "listNames"


    // $ANTLR start "mlTech"
    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:135:1: mlTech : ( MEMM | CRF | SVM );
    public final void mlTech() throws RecognitionException {
        try {
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:135:9: ( MEMM | CRF | SVM )
            int alt13=3;
            switch ( input.LA(1) ) {
            case MEMM:
                {
                alt13=1;
                }
                break;
            case CRF:
                {
                alt13=2;
                }
                break;
            case SVM:
                {
                alt13=3;
                }
                break;
            default:
                NoViableAltException nvae =
                    new NoViableAltException("", 13, 0, input);

                throw nvae;
            }

            switch (alt13) {
                case 1 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:135:11: MEMM
                    {
                    match(input,MEMM,FOLLOW_MEMM_in_mlTech464); 
                    current.setMachineLearningTechnique(ClassificationModelCreator.MLTechnique.MEMM);

                    }
                    break;
                case 2 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:136:5: CRF
                    {
                    match(input,CRF,FOLLOW_CRF_in_mlTech479); 
                    current.setMachineLearningTechnique(ClassificationModelCreator.MLTechnique.CRF);

                    }
                    break;
                case 3 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:137:5: SVM
                    {
                    match(input,SVM,FOLLOW_SVM_in_mlTech493); 
                    current.setMachineLearningTechnique(ClassificationModelCreator.MLTechnique.SVM);

                    }
                    break;

            }
        }
        catch (RecognitionException re) {
            reportError(re);
            recover(input,re);
        }
        finally {
        }
        return ;
    }
    // $ANTLR end "mlTech"


    // $ANTLR start "features"
    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:139:1: features : CAPTURING FEATURES listFeatures ( IN WINDOW WITH RADIUS NUMBER )? ;
    public final void features() throws RecognitionException {
        Token NUMBER13=null;

        try {
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:139:9: ( CAPTURING FEATURES listFeatures ( IN WINDOW WITH RADIUS NUMBER )? )
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:139:11: CAPTURING FEATURES listFeatures ( IN WINDOW WITH RADIUS NUMBER )?
            {
            match(input,CAPTURING,FOLLOW_CAPTURING_in_features508); 
            match(input,FEATURES,FOLLOW_FEATURES_in_features510); 
            pushFollow(FOLLOW_listFeatures_in_features512);
            listFeatures();

            state._fsp--;

            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:139:43: ( IN WINDOW WITH RADIUS NUMBER )?
            int alt14=2;
            int LA14_0 = input.LA(1);

            if ( (LA14_0==IN) ) {
                alt14=1;
            }
            switch (alt14) {
                case 1 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:139:44: IN WINDOW WITH RADIUS NUMBER
                    {
                    match(input,IN,FOLLOW_IN_in_features515); 
                    match(input,WINDOW,FOLLOW_WINDOW_in_features517); 
                    match(input,WITH,FOLLOW_WITH_in_features519); 
                    match(input,RADIUS,FOLLOW_RADIUS_in_features521); 
                    NUMBER13=(Token)match(input,NUMBER,FOLLOW_NUMBER_in_features523); 

                    }
                    break;

            }

            if(NUMBER13!=null){
                                  current.setFeaturesWindow(Integer.parseInt((NUMBER13!=null?NUMBER13.getText():null)));
                                  }

            }

        }
        catch (RecognitionException re) {
            reportError(re);
            recover(input,re);
        }
        finally {
        }
        return ;
    }
    // $ANTLR end "features"


    // $ANTLR start "listFeatures"
    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:143:1: listFeatures : ( feature | feature COMMA listFeatures );
    public final void listFeatures() throws RecognitionException {
        try {
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:144:3: ( feature | feature COMMA listFeatures )
            int alt15=2;
            alt15 = dfa15.predict(input);
            switch (alt15) {
                case 1 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:144:5: feature
                    {
                    pushFollow(FOLLOW_feature_in_listFeatures538);
                    feature();

                    state._fsp--;


                    }
                    break;
                case 2 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:145:5: feature COMMA listFeatures
                    {
                    pushFollow(FOLLOW_feature_in_listFeatures557);
                    feature();

                    state._fsp--;

                    match(input,COMMA,FOLLOW_COMMA_in_listFeatures559); 
                    pushFollow(FOLLOW_listFeatures_in_listFeatures561);
                    listFeatures();

                    state._fsp--;


                    }
                    break;

            }
        }
        catch (RecognitionException re) {
            reportError(re);
            recover(input,re);
        }
        finally {
        }
        return ;
    }
    // $ANTLR end "listFeatures"


    // $ANTLR start "feature"
    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:147:1: feature : ( CLASSIFICATION MODEL GENERIC_NAME | SUBSTRING FROM n1= NUMBER TO n2= NUMBER | DICTIONARY STRING | MATCH STRING | CASE SENSITIVE VALUE | CASE INSENSITIVE VALUE | SIZE | CHARACTER PATTERN | CHARACTER TYPE | UCOMPARE GENERIC_NAME );
    public final void feature() throws RecognitionException {
        Token n1=null;
        Token n2=null;
        Token GENERIC_NAME14=null;
        Token STRING15=null;
        Token STRING16=null;
        Token GENERIC_NAME17=null;

        try {
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:147:9: ( CLASSIFICATION MODEL GENERIC_NAME | SUBSTRING FROM n1= NUMBER TO n2= NUMBER | DICTIONARY STRING | MATCH STRING | CASE SENSITIVE VALUE | CASE INSENSITIVE VALUE | SIZE | CHARACTER PATTERN | CHARACTER TYPE | UCOMPARE GENERIC_NAME )
            int alt16=10;
            alt16 = dfa16.predict(input);
            switch (alt16) {
                case 1 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:147:11: CLASSIFICATION MODEL GENERIC_NAME
                    {
                    match(input,CLASSIFICATION,FOLLOW_CLASSIFICATION_in_feature571); 
                    match(input,MODEL,FOLLOW_MODEL_in_feature573); 
                    GENERIC_NAME14=(Token)match(input,GENERIC_NAME,FOLLOW_GENERIC_NAME_in_feature575); 

                            if(current.getFeaturesList() == null){
                              current.setFeaturesList(new ArrayList<CharacterFeatureClassifier>());
                            }
                            String annotatorName = (GENERIC_NAME14!=null?GENERIC_NAME14.getText():null) + ".ann";
                            String annotatorPath = "./annotators/"+annotatorName;
                            ClassificationModelSerializer serial = new ClassificationModelSerializer();
                            ClassificationModel annot = serial.deserializeClassificationModel(annotatorPath);
                            current.addFeature(new ClassificationModelFeatureClassifier(annot.getClassifier(),(GENERIC_NAME14!=null?GENERIC_NAME14.getText():null)));
                          

                    }
                    break;
                case 2 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:158:5: SUBSTRING FROM n1= NUMBER TO n2= NUMBER
                    {
                    match(input,SUBSTRING,FOLLOW_SUBSTRING_in_feature589); 
                    match(input,FROM,FOLLOW_FROM_in_feature591); 
                    n1=(Token)match(input,NUMBER,FOLLOW_NUMBER_in_feature595); 
                    match(input,TO,FOLLOW_TO_in_feature597); 
                    n2=(Token)match(input,NUMBER,FOLLOW_NUMBER_in_feature601); 

                            if(current.getFeaturesList() == null){
                              current.setFeaturesList(new ArrayList<CharacterFeatureClassifier>());
                            }
                            current.addFeature(new SubstringFeatureClassifier(Integer.parseInt((n1!=null?n1.getText():null)),
                                                                            Integer.parseInt((n2!=null?n2.getText():null))));
                          

                    }
                    break;
                case 3 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:166:5: DICTIONARY STRING
                    {
                    match(input,DICTIONARY,FOLLOW_DICTIONARY_in_feature620); 
                    STRING15=(Token)match(input,STRING,FOLLOW_STRING_in_feature622); 

                            if(current.getFeaturesList() == null){
                              current.setFeaturesList(new ArrayList<CharacterFeatureClassifier>());
                            }
                            try {
                              current.addFeature(new DictionaryFeatureClassifier((STRING15!=null?STRING15.getText():null).substring(1,(STRING15!=null?STRING15.getText():null).length()-1)));
                            }catch(IOException e){
                            
                            }
                          

                    }
                    break;
                case 4 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:177:5: MATCH STRING
                    {
                    match(input,MATCH,FOLLOW_MATCH_in_feature641); 
                    STRING16=(Token)match(input,STRING,FOLLOW_STRING_in_feature643); 

                            if(current.getFeaturesList() == null){
                              current.setFeaturesList(new ArrayList<CharacterFeatureClassifier>());
                            }
                            current.addFeature(new RegexFeatureClassifier((STRING16!=null?STRING16.getText():null).substring(1,(STRING16!=null?STRING16.getText():null).length()-1)));
                          

                    }
                    break;
                case 5 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:184:5: CASE SENSITIVE VALUE
                    {
                    match(input,CASE,FOLLOW_CASE_in_feature665); 
                    match(input,SENSITIVE,FOLLOW_SENSITIVE_in_feature667); 
                    match(input,VALUE,FOLLOW_VALUE_in_feature669); 

                            if(current.getFeaturesList() == null){
                              current.setFeaturesList(new ArrayList<CharacterFeatureClassifier>());
                            }
                            current.addFeature(new ValueCaseSensitiveFeatureClassifier());
                          

                    }
                    break;
                case 6 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:191:5: CASE INSENSITIVE VALUE
                    {
                    match(input,CASE,FOLLOW_CASE_in_feature693); 
                    match(input,INSENSITIVE,FOLLOW_INSENSITIVE_in_feature695); 
                    match(input,VALUE,FOLLOW_VALUE_in_feature697); 

                            if(current.getFeaturesList() == null){
                              current.setFeaturesList(new ArrayList<CharacterFeatureClassifier>());
                            }
                            current.addFeature(new ValueCaseInsensitiveFeatureClassifier());
                          

                    }
                    break;
                case 7 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:198:5: SIZE
                    {
                    match(input,SIZE,FOLLOW_SIZE_in_feature721); 

                            if(current.getFeaturesList() == null){
                              current.setFeaturesList(new ArrayList<CharacterFeatureClassifier>());
                            }
                            current.addFeature(new SizeFeatureClassifier());
                          

                    }
                    break;
                case 8 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:205:5: CHARACTER PATTERN
                    {
                    match(input,CHARACTER,FOLLOW_CHARACTER_in_feature749); 
                    match(input,PATTERN,FOLLOW_PATTERN_in_feature751); 

                            if(current.getFeaturesList() == null){
                              current.setFeaturesList(new ArrayList<CharacterFeatureClassifier>());
                            }
                            current.addFeature(new PatternFeatureClassifier());
                          

                    }
                    break;
                case 9 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:212:5: CHARACTER TYPE
                    {
                    match(input,CHARACTER,FOLLOW_CHARACTER_in_feature774); 
                    match(input,TYPE,FOLLOW_TYPE_in_feature776); 

                            if(current.getFeaturesList() == null){
                              current.setFeaturesList(new ArrayList<CharacterFeatureClassifier>());
                            }
                            current.addFeature(new CharacterTypeFeatureClassifier());
                          

                    }
                    break;
                case 10 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:219:5: UCOMPARE GENERIC_NAME
                    {
                    match(input,UCOMPARE,FOLLOW_UCOMPARE_in_feature802); 
                    GENERIC_NAME17=(Token)match(input,GENERIC_NAME,FOLLOW_GENERIC_NAME_in_feature804); 

                            if(current.getUCompareFeaturesList() == null){
                              current.setUCompareFeaturesList(new ArrayList<String>());
                            }
                            current.addUCompareFeature(new String((GENERIC_NAME17!=null?GENERIC_NAME17.getText():null)));
                            if(current.getFeaturesList() == null){
                              current.setFeaturesList(new ArrayList<CharacterFeatureClassifier>());
                            }
                            current.addFeature(new UCompareAnnotationFeatureClassifier(new String((GENERIC_NAME17!=null?GENERIC_NAME17.getText():null))));
                          

                    }
                    break;

            }
        }
        catch (RecognitionException re) {
            reportError(re);
            recover(input,re);
        }
        finally {
        }
        return ;
    }
    // $ANTLR end "feature"


    // $ANTLR start "classify"
    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:231:1: classify : CLASSIFY listClasses FROM STRING USING GENERIC_NAME ;
    public final void classify() throws RecognitionException {
        Token GENERIC_NAME18=null;
        Token STRING19=null;

        try {
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:231:9: ( CLASSIFY listClasses FROM STRING USING GENERIC_NAME )
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:231:11: CLASSIFY listClasses FROM STRING USING GENERIC_NAME
            {
            match(input,CLASSIFY,FOLLOW_CLASSIFY_in_classify821); 
            pushFollow(FOLLOW_listClasses_in_classify823);
            listClasses();

            state._fsp--;

            match(input,FROM,FOLLOW_FROM_in_classify829); 
            STRING19=(Token)match(input,STRING,FOLLOW_STRING_in_classify831); 
            match(input,USING,FOLLOW_USING_in_classify837); 
            GENERIC_NAME18=(Token)match(input,GENERIC_NAME,FOLLOW_GENERIC_NAME_in_classify839); 
            current.setAnnotatorName((GENERIC_NAME18!=null?GENERIC_NAME18.getText():null)); current.setTestingFile((STRING19!=null?STRING19.getText():null).substring(1,(STRING19!=null?STRING19.getText():null).length()-1));

            }

        }
        catch (RecognitionException re) {
            reportError(re);
            recover(input,re);
        }
        finally {
        }
        return ;
    }
    // $ANTLR end "classify"


    // $ANTLR start "evaluate"
    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:235:1: evaluate : EVALUATE CLASSIFICATION OF listClasses FROM STRING USING GENERIC_NAME ;
    public final void evaluate() throws RecognitionException {
        Token GENERIC_NAME20=null;
        Token STRING21=null;

        try {
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:235:9: ( EVALUATE CLASSIFICATION OF listClasses FROM STRING USING GENERIC_NAME )
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:235:11: EVALUATE CLASSIFICATION OF listClasses FROM STRING USING GENERIC_NAME
            {
            match(input,EVALUATE,FOLLOW_EVALUATE_in_evaluate849); 
            match(input,CLASSIFICATION,FOLLOW_CLASSIFICATION_in_evaluate851); 
            match(input,OF,FOLLOW_OF_in_evaluate853); 
            pushFollow(FOLLOW_listClasses_in_evaluate855);
            listClasses();

            state._fsp--;

            match(input,FROM,FOLLOW_FROM_in_evaluate861); 
            STRING21=(Token)match(input,STRING,FOLLOW_STRING_in_evaluate863); 
            match(input,USING,FOLLOW_USING_in_evaluate869); 
            GENERIC_NAME20=(Token)match(input,GENERIC_NAME,FOLLOW_GENERIC_NAME_in_evaluate871); 
            current.setAnnotatorName((GENERIC_NAME20!=null?GENERIC_NAME20.getText():null)); current.setTestingFile((STRING21!=null?STRING21.getText():null).substring(1,(STRING21!=null?STRING21.getText():null).length()-1));

            }

        }
        catch (RecognitionException re) {
            reportError(re);
            recover(input,re);
        }
        finally {
        }
        return ;
    }
    // $ANTLR end "evaluate"


    // $ANTLR start "setBeginTag"
    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:239:1: setBeginTag : SET BEGIN TAG STRING ;
    public final void setBeginTag() throws RecognitionException {
        Token STRING22=null;

        try {
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:240:3: ( SET BEGIN TAG STRING )
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:240:5: SET BEGIN TAG STRING
            {
            match(input,SET,FOLLOW_SET_in_setBeginTag887); 
            match(input,BEGIN,FOLLOW_BEGIN_in_setBeginTag889); 
            match(input,TAG,FOLLOW_TAG_in_setBeginTag891); 
            STRING22=(Token)match(input,STRING,FOLLOW_STRING_in_setBeginTag893); 
            current.setBeginTag((STRING22!=null?STRING22.getText():null).substring(1,(STRING22!=null?STRING22.getText():null).length()-1));

            }

        }
        catch (RecognitionException re) {
            reportError(re);
            recover(input,re);
        }
        finally {
        }
        return ;
    }
    // $ANTLR end "setBeginTag"


    // $ANTLR start "setEndTag"
    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:242:1: setEndTag : SET END TAG STRING ;
    public final void setEndTag() throws RecognitionException {
        Token STRING23=null;

        try {
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:243:3: ( SET END TAG STRING )
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:243:5: SET END TAG STRING
            {
            match(input,SET,FOLLOW_SET_in_setEndTag907); 
            match(input,END,FOLLOW_END_in_setEndTag909); 
            match(input,TAG,FOLLOW_TAG_in_setEndTag911); 
            STRING23=(Token)match(input,STRING,FOLLOW_STRING_in_setEndTag913); 
            current.setEndTag((STRING23!=null?STRING23.getText():null).substring(1,(STRING23!=null?STRING23.getText():null).length()-1));

            }

        }
        catch (RecognitionException re) {
            reportError(re);
            recover(input,re);
        }
        finally {
        }
        return ;
    }
    // $ANTLR end "setEndTag"


    // $ANTLR start "setDocPerFile"
    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:245:1: setDocPerFile : SET DOCUMENT STYLE documentStyle ;
    public final void setDocPerFile() throws RecognitionException {
        try {
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:246:3: ( SET DOCUMENT STYLE documentStyle )
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:246:5: SET DOCUMENT STYLE documentStyle
            {
            match(input,SET,FOLLOW_SET_in_setDocPerFile927); 
            match(input,DOCUMENT,FOLLOW_DOCUMENT_in_setDocPerFile929); 
            match(input,STYLE,FOLLOW_STYLE_in_setDocPerFile931); 
            pushFollow(FOLLOW_documentStyle_in_setDocPerFile933);
            documentStyle();

            state._fsp--;


            }

        }
        catch (RecognitionException re) {
            reportError(re);
            recover(input,re);
        }
        finally {
        }
        return ;
    }
    // $ANTLR end "setDocPerFile"


    // $ANTLR start "documentStyle"
    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:248:1: documentStyle : ( ONE DOCUMENT PER LINE | ONE DOCUMENT PER FILE );
    public final void documentStyle() throws RecognitionException {
        try {
            // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:249:3: ( ONE DOCUMENT PER LINE | ONE DOCUMENT PER FILE )
            int alt17=2;
            int LA17_0 = input.LA(1);

            if ( (LA17_0==ONE) ) {
                int LA17_1 = input.LA(2);

                if ( (LA17_1==DOCUMENT) ) {
                    int LA17_2 = input.LA(3);

                    if ( (LA17_2==PER) ) {
                        int LA17_3 = input.LA(4);

                        if ( (LA17_3==LINE) ) {
                            alt17=1;
                        }
                        else if ( (LA17_3==FILE) ) {
                            alt17=2;
                        }
                        else {
                            NoViableAltException nvae =
                                new NoViableAltException("", 17, 3, input);

                            throw nvae;
                        }
                    }
                    else {
                        NoViableAltException nvae =
                            new NoViableAltException("", 17, 2, input);

                        throw nvae;
                    }
                }
                else {
                    NoViableAltException nvae =
                        new NoViableAltException("", 17, 1, input);

                    throw nvae;
                }
            }
            else {
                NoViableAltException nvae =
                    new NoViableAltException("", 17, 0, input);

                throw nvae;
            }
            switch (alt17) {
                case 1 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:249:5: ONE DOCUMENT PER LINE
                    {
                    match(input,ONE,FOLLOW_ONE_in_documentStyle945); 
                    match(input,DOCUMENT,FOLLOW_DOCUMENT_in_documentStyle947); 
                    match(input,PER,FOLLOW_PER_in_documentStyle949); 
                    match(input,LINE,FOLLOW_LINE_in_documentStyle951); 
                    current.setDocPerFile(false);

                    }
                    break;
                case 2 :
                    // /home/goncalo/Dropbox/Etxt2db/Etxt2dbComponent/src/etxt2db/ucompare/query/Etxt2DBGrammar.g:250:5: ONE DOCUMENT PER FILE
                    {
                    match(input,ONE,FOLLOW_ONE_in_documentStyle959); 
                    match(input,DOCUMENT,FOLLOW_DOCUMENT_in_documentStyle961); 
                    match(input,PER,FOLLOW_PER_in_documentStyle963); 
                    match(input,FILE,FOLLOW_FILE_in_documentStyle965); 
                    current.setDocPerFile(true);

                    }
                    break;

            }
        }
        catch (RecognitionException re) {
            reportError(re);
            recover(input,re);
        }
        finally {
        }
        return ;
    }
    // $ANTLR end "documentStyle"

    // Delegated rules


    protected DFA15 dfa15 = new DFA15(this);
    protected DFA16 dfa16 = new DFA16(this);
    static final String DFA15_eotS =
        "\32\uffff";
    static final String DFA15_eofS =
        "\6\uffff\1\17\4\uffff\2\17\4\uffff\4\17\1\uffff\2\17\1\uffff\1\17";
    static final String DFA15_minS =
        "\1\5\1\6\1\50\2\12\1\34\1\4\1\55\2\10\1\46\2\4\2\52\2\uffff\4\4"+
        "\1\24\2\4\1\46\1\4";
    static final String DFA15_maxS =
        "\1\54\1\6\1\50\2\12\1\35\1\62\1\56\2\10\1\46\2\62\2\52\2\uffff\4"+
        "\62\1\24\2\62\1\46\1\62";
    static final String DFA15_acceptS =
        "\17\uffff\1\1\1\2\11\uffff";
    static final String DFA15_specialS =
        "\32\uffff}>";
    static final String[] DFA15_transitionS = {
            "\1\1\13\uffff\1\10\4\uffff\1\3\4\uffff\1\5\13\uffff\1\2\1\uffff"+
            "\1\4\1\uffff\1\6\1\7",
            "\1\11",
            "\1\12",
            "\1\13",
            "\1\14",
            "\1\15\1\16",
            "\1\17\25\uffff\1\20\10\uffff\1\17\13\uffff\2\17\1\uffff\1\17",
            "\1\21\1\22",
            "\1\23",
            "\1\24",
            "\1\25",
            "\1\17\25\uffff\1\20\10\uffff\1\17\13\uffff\2\17\1\uffff\1\17",
            "\1\17\25\uffff\1\20\10\uffff\1\17\13\uffff\2\17\1\uffff\1\17",
            "\1\26",
            "\1\27",
            "",
            "",
            "\1\17\25\uffff\1\20\10\uffff\1\17\13\uffff\2\17\1\uffff\1\17",
            "\1\17\25\uffff\1\20\10\uffff\1\17\13\uffff\2\17\1\uffff\1\17",
            "\1\17\25\uffff\1\20\10\uffff\1\17\13\uffff\2\17\1\uffff\1\17",
            "\1\17\25\uffff\1\20\10\uffff\1\17\13\uffff\2\17\1\uffff\1\17",
            "\1\30",
            "\1\17\25\uffff\1\20\10\uffff\1\17\13\uffff\2\17\1\uffff\1\17",
            "\1\17\25\uffff\1\20\10\uffff\1\17\13\uffff\2\17\1\uffff\1\17",
            "\1\31",
            "\1\17\25\uffff\1\20\10\uffff\1\17\13\uffff\2\17\1\uffff\1\17"
    };

    static final short[] DFA15_eot = DFA.unpackEncodedString(DFA15_eotS);
    static final short[] DFA15_eof = DFA.unpackEncodedString(DFA15_eofS);
    static final char[] DFA15_min = DFA.unpackEncodedStringToUnsignedChars(DFA15_minS);
    static final char[] DFA15_max = DFA.unpackEncodedStringToUnsignedChars(DFA15_maxS);
    static final short[] DFA15_accept = DFA.unpackEncodedString(DFA15_acceptS);
    static final short[] DFA15_special = DFA.unpackEncodedString(DFA15_specialS);
    static final short[][] DFA15_transition;

    static {
        int numStates = DFA15_transitionS.length;
        DFA15_transition = new short[numStates][];
        for (int i=0; i<numStates; i++) {
            DFA15_transition[i] = DFA.unpackEncodedString(DFA15_transitionS[i]);
        }
    }

    class DFA15 extends DFA {

        public DFA15(BaseRecognizer recognizer) {
            this.recognizer = recognizer;
            this.decisionNumber = 15;
            this.eot = DFA15_eot;
            this.eof = DFA15_eof;
            this.min = DFA15_min;
            this.max = DFA15_max;
            this.accept = DFA15_accept;
            this.special = DFA15_special;
            this.transition = DFA15_transition;
        }
        public String getDescription() {
            return "143:1: listFeatures : ( feature | feature COMMA listFeatures );";
        }
    }
    static final String DFA16_eotS =
        "\15\uffff";
    static final String DFA16_eofS =
        "\15\uffff";
    static final String DFA16_minS =
        "\1\5\4\uffff\1\34\1\uffff\1\55\5\uffff";
    static final String DFA16_maxS =
        "\1\54\4\uffff\1\35\1\uffff\1\56\5\uffff";
    static final String DFA16_acceptS =
        "\1\uffff\1\1\1\2\1\3\1\4\1\uffff\1\7\1\uffff\1\12\1\5\1\6\1\10\1"+
        "\11";
    static final String DFA16_specialS =
        "\15\uffff}>";
    static final String[] DFA16_transitionS = {
            "\1\1\13\uffff\1\10\4\uffff\1\3\4\uffff\1\5\13\uffff\1\2\1\uffff"+
            "\1\4\1\uffff\1\6\1\7",
            "",
            "",
            "",
            "",
            "\1\11\1\12",
            "",
            "\1\13\1\14",
            "",
            "",
            "",
            "",
            ""
    };

    static final short[] DFA16_eot = DFA.unpackEncodedString(DFA16_eotS);
    static final short[] DFA16_eof = DFA.unpackEncodedString(DFA16_eofS);
    static final char[] DFA16_min = DFA.unpackEncodedStringToUnsignedChars(DFA16_minS);
    static final char[] DFA16_max = DFA.unpackEncodedStringToUnsignedChars(DFA16_maxS);
    static final short[] DFA16_accept = DFA.unpackEncodedString(DFA16_acceptS);
    static final short[] DFA16_special = DFA.unpackEncodedString(DFA16_specialS);
    static final short[][] DFA16_transition;

    static {
        int numStates = DFA16_transitionS.length;
        DFA16_transition = new short[numStates][];
        for (int i=0; i<numStates; i++) {
            DFA16_transition[i] = DFA.unpackEncodedString(DFA16_transitionS[i]);
        }
    }

    class DFA16 extends DFA {

        public DFA16(BaseRecognizer recognizer) {
            this.recognizer = recognizer;
            this.decisionNumber = 16;
            this.eot = DFA16_eot;
            this.eof = DFA16_eof;
            this.min = DFA16_min;
            this.max = DFA16_max;
            this.accept = DFA16_accept;
            this.special = DFA16_special;
            this.transition = DFA16_transition;
        }
        public String getDescription() {
            return "147:1: feature : ( CLASSIFICATION MODEL GENERIC_NAME | SUBSTRING FROM n1= NUMBER TO n2= NUMBER | DICTIONARY STRING | MATCH STRING | CASE SENSITIVE VALUE | CASE INSENSITIVE VALUE | SIZE | CHARACTER PATTERN | CHARACTER TYPE | UCOMPARE GENERIC_NAME );";
        }
    }
 

    public static final BitSet FOLLOW_train_in_root35 = new BitSet(new long[]{0x0005800000000012L});
    public static final BitSet FOLLOW_classify_in_root44 = new BitSet(new long[]{0x0005800000000012L});
    public static final BitSet FOLLOW_evaluate_in_root53 = new BitSet(new long[]{0x0005800000000012L});
    public static final BitSet FOLLOW_setBeginTag_in_root61 = new BitSet(new long[]{0x0005800000000012L});
    public static final BitSet FOLLOW_setEndTag_in_root70 = new BitSet(new long[]{0x0005800000000012L});
    public static final BitSet FOLLOW_setDocPerFile_in_root78 = new BitSet(new long[]{0x0005800000000012L});
    public static final BitSet FOLLOW_trainHeader_in_train94 = new BitSet(new long[]{0x0000000000050A00L});
    public static final BitSet FOLLOW_workflow_in_train96 = new BitSet(new long[]{0x0000000000050A00L});
    public static final BitSet FOLLOW_context_in_train99 = new BitSet(new long[]{0x0000000000050A00L});
    public static final BitSet FOLLOW_tokenization_in_train102 = new BitSet(new long[]{0x0000000000050A00L});
    public static final BitSet FOLLOW_technique_in_train105 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_CREATE_in_trainHeader119 = new BitSet(new long[]{0x0000000000000020L});
    public static final BitSet FOLLOW_CLASSIFICATION_in_trainHeader121 = new BitSet(new long[]{0x0000000000000040L});
    public static final BitSet FOLLOW_MODEL_in_trainHeader123 = new BitSet(new long[]{0x0000000000000080L});
    public static final BitSet FOLLOW_AS_in_trainHeader125 = new BitSet(new long[]{0x0000000000000100L});
    public static final BitSet FOLLOW_GENERIC_NAME_in_trainHeader127 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_WITH_in_workflow139 = new BitSet(new long[]{0x0000000000000400L});
    public static final BitSet FOLLOW_STRING_in_workflow141 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_CONTEXT_in_context154 = new BitSet(new long[]{0x000000000000F000L});
    public static final BitSet FOLLOW_context_name_in_context156 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_DOCUMENT_in_context_name165 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_PARAGRAPH_in_context_name173 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_SENTENCE_in_context_name181 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_LINE_in_context_name189 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_TOKENIZED_in_tokenization201 = new BitSet(new long[]{0x0000000000000200L});
    public static final BitSet FOLLOW_WITH_in_tokenization203 = new BitSet(new long[]{0x0000000000020000L});
    public static final BitSet FOLLOW_UCOMPARE_in_tokenization205 = new BitSet(new long[]{0x0000000000000100L});
    public static final BitSet FOLLOW_GENERIC_NAME_in_tokenization207 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_USING_in_technique220 = new BitSet(new long[]{0x0000000000080000L});
    public static final BitSet FOLLOW_REGEX_in_technique222 = new BitSet(new long[]{0x0000000000000400L});
    public static final BitSet FOLLOW_STRING_in_technique224 = new BitSet(new long[]{0x0000000000100000L});
    public static final BitSet FOLLOW_TO_in_technique226 = new BitSet(new long[]{0x0000000000200000L});
    public static final BitSet FOLLOW_FIND_in_technique228 = new BitSet(new long[]{0x0000000000000100L});
    public static final BitSet FOLLOW_GENERIC_NAME_in_technique230 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_USING_in_technique240 = new BitSet(new long[]{0x0000000008400000L});
    public static final BitSet FOLLOW_caseSelection_in_technique242 = new BitSet(new long[]{0x0000000000400000L});
    public static final BitSet FOLLOW_DICTIONARY_in_technique245 = new BitSet(new long[]{0x0000000000000400L});
    public static final BitSet FOLLOW_STRING_in_technique247 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_USING_in_technique258 = new BitSet(new long[]{0x0000000000800000L});
    public static final BitSet FOLLOW_HMM_in_technique260 = new BitSet(new long[]{0x0000000001000000L});
    public static final BitSet FOLLOW_TRAINED_in_technique262 = new BitSet(new long[]{0x0000000000000200L});
    public static final BitSet FOLLOW_WITH_in_technique264 = new BitSet(new long[]{0x0000000000000400L});
    public static final BitSet FOLLOW_STRING_in_technique266 = new BitSet(new long[]{0x0000000000100000L});
    public static final BitSet FOLLOW_TO_in_technique268 = new BitSet(new long[]{0x0000000000200000L});
    public static final BitSet FOLLOW_FIND_in_technique270 = new BitSet(new long[]{0x0000000000000100L,0x0000000010000000L});
    public static final BitSet FOLLOW_listClasses_in_technique272 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_USING_in_technique296 = new BitSet(new long[]{0x00000001C0000000L});
    public static final BitSet FOLLOW_mlTech_in_technique298 = new BitSet(new long[]{0x0000000001000000L});
    public static final BitSet FOLLOW_TRAINED_in_technique300 = new BitSet(new long[]{0x0000000000000200L});
    public static final BitSet FOLLOW_WITH_in_technique302 = new BitSet(new long[]{0x0000000000000400L});
    public static final BitSet FOLLOW_STRING_in_technique304 = new BitSet(new long[]{0x0000000000100000L});
    public static final BitSet FOLLOW_TO_in_technique306 = new BitSet(new long[]{0x0000000000200000L});
    public static final BitSet FOLLOW_FIND_in_technique308 = new BitSet(new long[]{0x0000000000000100L,0x0000000010000000L});
    public static final BitSet FOLLOW_listClasses_in_technique310 = new BitSet(new long[]{0x0000000200000002L});
    public static final BitSet FOLLOW_features_in_technique312 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_USING_in_technique331 = new BitSet(new long[]{0x0000000000000020L});
    public static final BitSet FOLLOW_CLASSIFICATION_in_technique333 = new BitSet(new long[]{0x0000000000000040L});
    public static final BitSet FOLLOW_MODEL_in_technique335 = new BitSet(new long[]{0x0000000002000000L});
    public static final BitSet FOLLOW_UNION_in_technique337 = new BitSet(new long[]{0x0000000000000100L});
    public static final BitSet FOLLOW_listClassifiers_in_technique339 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_GENERIC_NAME_in_listClassifiers352 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_GENERIC_NAME_in_listClassifiers367 = new BitSet(new long[]{0x0000000004000000L});
    public static final BitSet FOLLOW_COMMA_in_listClassifiers369 = new BitSet(new long[]{0x0000000000000100L});
    public static final BitSet FOLLOW_listClassifiers_in_listClassifiers371 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_CASE_in_caseSelection385 = new BitSet(new long[]{0x0000000030000000L});
    public static final BitSet FOLLOW_SENSITIVE_in_caseSelection389 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_INSENSITIVE_in_caseSelection396 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_listNames_in_listClasses410 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_92_in_listClasses417 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_GENERIC_NAME_in_listNames433 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_GENERIC_NAME_in_listNames446 = new BitSet(new long[]{0x0000000004000000L});
    public static final BitSet FOLLOW_COMMA_in_listNames448 = new BitSet(new long[]{0x0000000000000100L});
    public static final BitSet FOLLOW_listNames_in_listNames450 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_MEMM_in_mlTech464 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_CRF_in_mlTech479 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_SVM_in_mlTech493 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_CAPTURING_in_features508 = new BitSet(new long[]{0x0000000400000000L});
    public static final BitSet FOLLOW_FEATURES_in_features510 = new BitSet(new long[]{0x00001A8008420020L});
    public static final BitSet FOLLOW_listFeatures_in_features512 = new BitSet(new long[]{0x0000000800000002L});
    public static final BitSet FOLLOW_IN_in_features515 = new BitSet(new long[]{0x0000001000000000L});
    public static final BitSet FOLLOW_WINDOW_in_features517 = new BitSet(new long[]{0x0000000000000200L});
    public static final BitSet FOLLOW_WITH_in_features519 = new BitSet(new long[]{0x0000002000000000L});
    public static final BitSet FOLLOW_RADIUS_in_features521 = new BitSet(new long[]{0x0000004000000000L});
    public static final BitSet FOLLOW_NUMBER_in_features523 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_feature_in_listFeatures538 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_feature_in_listFeatures557 = new BitSet(new long[]{0x0000000004000000L});
    public static final BitSet FOLLOW_COMMA_in_listFeatures559 = new BitSet(new long[]{0x00001A8008420020L});
    public static final BitSet FOLLOW_listFeatures_in_listFeatures561 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_CLASSIFICATION_in_feature571 = new BitSet(new long[]{0x0000000000000040L});
    public static final BitSet FOLLOW_MODEL_in_feature573 = new BitSet(new long[]{0x0000000000000100L});
    public static final BitSet FOLLOW_GENERIC_NAME_in_feature575 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_SUBSTRING_in_feature589 = new BitSet(new long[]{0x0000010000000000L});
    public static final BitSet FOLLOW_FROM_in_feature591 = new BitSet(new long[]{0x0000004000000000L});
    public static final BitSet FOLLOW_NUMBER_in_feature595 = new BitSet(new long[]{0x0000000000100000L});
    public static final BitSet FOLLOW_TO_in_feature597 = new BitSet(new long[]{0x0000004000000000L});
    public static final BitSet FOLLOW_NUMBER_in_feature601 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_DICTIONARY_in_feature620 = new BitSet(new long[]{0x0000000000000400L});
    public static final BitSet FOLLOW_STRING_in_feature622 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_MATCH_in_feature641 = new BitSet(new long[]{0x0000000000000400L});
    public static final BitSet FOLLOW_STRING_in_feature643 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_CASE_in_feature665 = new BitSet(new long[]{0x0000000010000000L});
    public static final BitSet FOLLOW_SENSITIVE_in_feature667 = new BitSet(new long[]{0x0000040000000000L});
    public static final BitSet FOLLOW_VALUE_in_feature669 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_CASE_in_feature693 = new BitSet(new long[]{0x0000000020000000L});
    public static final BitSet FOLLOW_INSENSITIVE_in_feature695 = new BitSet(new long[]{0x0000040000000000L});
    public static final BitSet FOLLOW_VALUE_in_feature697 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_SIZE_in_feature721 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_CHARACTER_in_feature749 = new BitSet(new long[]{0x0000200000000000L});
    public static final BitSet FOLLOW_PATTERN_in_feature751 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_CHARACTER_in_feature774 = new BitSet(new long[]{0x0000400000000000L});
    public static final BitSet FOLLOW_TYPE_in_feature776 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_UCOMPARE_in_feature802 = new BitSet(new long[]{0x0000000000000100L});
    public static final BitSet FOLLOW_GENERIC_NAME_in_feature804 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_CLASSIFY_in_classify821 = new BitSet(new long[]{0x0000000000000100L,0x0000000010000000L});
    public static final BitSet FOLLOW_listClasses_in_classify823 = new BitSet(new long[]{0x0000010000000000L});
    public static final BitSet FOLLOW_FROM_in_classify829 = new BitSet(new long[]{0x0000000000000400L});
    public static final BitSet FOLLOW_STRING_in_classify831 = new BitSet(new long[]{0x0000000000040000L});
    public static final BitSet FOLLOW_USING_in_classify837 = new BitSet(new long[]{0x0000000000000100L});
    public static final BitSet FOLLOW_GENERIC_NAME_in_classify839 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_EVALUATE_in_evaluate849 = new BitSet(new long[]{0x0000000000000020L});
    public static final BitSet FOLLOW_CLASSIFICATION_in_evaluate851 = new BitSet(new long[]{0x0002000000000000L});
    public static final BitSet FOLLOW_OF_in_evaluate853 = new BitSet(new long[]{0x0000000000000100L,0x0000000010000000L});
    public static final BitSet FOLLOW_listClasses_in_evaluate855 = new BitSet(new long[]{0x0000010000000000L});
    public static final BitSet FOLLOW_FROM_in_evaluate861 = new BitSet(new long[]{0x0000000000000400L});
    public static final BitSet FOLLOW_STRING_in_evaluate863 = new BitSet(new long[]{0x0000000000040000L});
    public static final BitSet FOLLOW_USING_in_evaluate869 = new BitSet(new long[]{0x0000000000000100L});
    public static final BitSet FOLLOW_GENERIC_NAME_in_evaluate871 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_SET_in_setBeginTag887 = new BitSet(new long[]{0x0008000000000000L});
    public static final BitSet FOLLOW_BEGIN_in_setBeginTag889 = new BitSet(new long[]{0x0010000000000000L});
    public static final BitSet FOLLOW_TAG_in_setBeginTag891 = new BitSet(new long[]{0x0000000000000400L});
    public static final BitSet FOLLOW_STRING_in_setBeginTag893 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_SET_in_setEndTag907 = new BitSet(new long[]{0x0020000000000000L});
    public static final BitSet FOLLOW_END_in_setEndTag909 = new BitSet(new long[]{0x0010000000000000L});
    public static final BitSet FOLLOW_TAG_in_setEndTag911 = new BitSet(new long[]{0x0000000000000400L});
    public static final BitSet FOLLOW_STRING_in_setEndTag913 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_SET_in_setDocPerFile927 = new BitSet(new long[]{0x0000000000001000L});
    public static final BitSet FOLLOW_DOCUMENT_in_setDocPerFile929 = new BitSet(new long[]{0x0040000000000000L});
    public static final BitSet FOLLOW_STYLE_in_setDocPerFile931 = new BitSet(new long[]{0x0080000000000000L});
    public static final BitSet FOLLOW_documentStyle_in_setDocPerFile933 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_ONE_in_documentStyle945 = new BitSet(new long[]{0x0000000000001000L});
    public static final BitSet FOLLOW_DOCUMENT_in_documentStyle947 = new BitSet(new long[]{0x0100000000000000L});
    public static final BitSet FOLLOW_PER_in_documentStyle949 = new BitSet(new long[]{0x0000000000008000L});
    public static final BitSet FOLLOW_LINE_in_documentStyle951 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_ONE_in_documentStyle959 = new BitSet(new long[]{0x0000000000001000L});
    public static final BitSet FOLLOW_DOCUMENT_in_documentStyle961 = new BitSet(new long[]{0x0100000000000000L});
    public static final BitSet FOLLOW_PER_in_documentStyle963 = new BitSet(new long[]{0x0200000000000000L});
    public static final BitSet FOLLOW_FILE_in_documentStyle965 = new BitSet(new long[]{0x0000000000000002L});

}